From : Bruce Webster (exti151@cantva.canterbury.ac.nz)
Subject : How to operate with more than 1024 shapes
You could load 1023 shapes for fast access, and have one more shape
"slot" for copying the 32-byte shape object newtype into of
rarely-used shapes.

Ie, you load 1024 shapes, then copy ALL 1024 shape newtypes starting
at addr shape(0) somewhere else.  Then load another _1023_ shapes.
If you want one of the first 1024, copy the relevent 32 bytes into
addr shape(1023) and blit shape number 1023.  Of course you can load
as many blocks of 1024 as you like with this method.


But there is a faster way.  Theres the utterly grotty way I worked out:
(the too-easy, instant, evil, sneaky method that is not guaranteed to
work if Acid change the compiler...  (The "magical move" might need
changing!)

;-----------------
InitialShapeBank.l=Addr Shape(0)  ;this line MUST be at
                                  ;very start of program!!!

;mentioning shapes here makes the compiler set up the shape-lib's variables.
;Putting it at the start of the prog assures a constant offset in the
;global variable table (offset from A5)

DEFTYPE .w

Statement changeshapebank{bankadd.l}
MOVE.l d0,-32736(a5)    ;the magical move - we're writing to the
AsmExit                 ;shape-lib's pointer variable here!
End Statement           ;This is not an example of my usual coding practise.

InitBank 1,32*1024,$10000

Screen 0,3,"Bla"
ScreensBitMap 0,0

LoadShapes 0,"blitz2:rock3/gfx/rockshapes2"
changeshapebank{Bank(1)}

LoadShapes 1,"blitz2:rock3/gfx/rockshapes2"

Block 1,0,0      ;block a shape from one bank

changeshapebank{InitialShapeBank}

Block 1,0,128    ;block a shape from another bank.

End

;-----------------   Wow, that's sneaky!  (and very naughty)

Now if the compiler just knew to use longword instructions when we've
ASKED for LOTS OF OBJECTS in the OPTIONS!!  It's not just shapes that
are limited!  I stopped short of hacking the compiler object code.